import React from 'react';
import { Text, View } from 'react-native';
import Icon from 'react-native-vector-icons/MaterialIcons';
import styles from './style.js';

export default ({
  style,
  title = '暂无数据',
  icon = 'border-clear',
  children
}) => {
  return (
    <View style={[styles.wrap, style]}>
      <Icon name={icon} size={96} color="#aaa" />
      <Text style={styles.title}>{title}</Text>
      <View style={styles.children}>{children}</View>
    </View>
  );
};
